<!--
 * @Author: wangming
 * @Date: 2021-10-28 16:22:08
 * @LastEditors: wangming
 * @LastEditTime: 2022-05-17 10:52:04
 * @FilePath: /hanma-paas-mobile-fed/Users/wm/瀚川/hanma-application-designer-fed/src/pageComponents/formItem_desgic/unform.vue
 * @Description:  设计器内部表单外部
--> 
<template>
  <div class="ks-row-middle lhlabel">
    <div
      v-if="!config.__config.noItem"
      class="f14 g6"
      :style="{ width: config.__config.labelWidth + 'px' }"
    >
      {{ config.__config.label }}
    </div>
    <component
      class="ks-col"
      :disabled="config.__config.disabled"
      isEdit
      :is="config.tagName"
      :form="form"
      :config="config"
      v-model="form[config.modelName]"
    ></component>
  </div>
</template>

<script>
import myformComponents from "@/pageComponents/components/__form/index.js";
export default {
  components: { ...myformComponents },
  props: {
    form: {
      type: Object,
      default: () => ({}),
    },
    config: {
      type: Object,
      default: () => ({}),
    },
  },
  data() {
    return {};
  },
  async created() {
    this.$set(this.config, "isFormLayout", false);
  },
};
</script>

<style lang="scss" scoped>
.lhlabel {
  line-height: 32px;
}
</style>
